import request from '../utils/request'
// 获取评论
export const getCommend = (params) => {
  return request({
    url: '/v1_0/comments',
    params
  })
}

// 评论点赞
export const commentLike = (data) => {
  return request({
    url: '/v1_0/comment/likings',
    method: 'post',
    data
  })
}

// 取消评论点赞
export const nocommentLike = (target) => {
  return request({
    url: `/v1_0/comment/likings/${target}`,
    method: 'DELETE'
  })
}

// 评论
export const comment = (data) => {
  return request({
    url: '/v1_0/comments',
    method: 'post',
    data
  })
}
